import Vue from 'vue'

// 事件总线 EventBus
export const eventBus = new Vue()

import App from './App.vue'
import store from '@/store';

/* 
// 引入vue-router
import VueRouter from 'vue-router'
// 使用路由
Vue.use(VueRouter)
// 定义路由组件
import Home from './components/Home.vue'
import Learn from './components/Learn.vue'
import Student from './components/Student.vue'
import About from './components/About.vue'
import Activity from './components/Activity.vue'
// 定义路由
const routes = [ // 路由信息，路径，组件
  {path: '/', component: Home},
  {path: '/learn', component: Learn},
  {path: '/student', component: Student},
  {path: '/about', component: About},
  {path: '/activity', component: Activity}
]
// 创建router实例，能后传router配置。VueRouter是一个构造函数
const router = new VueRouter({
  routes, // 配置
}) 
*/

// 引入清除某些默认样式文件
import './assets/reset.css'
// 引入配置好的路由配置
import router from './router'

// 配置组件
import iView from 'iview'
import 'iview/dist/styles/iview.css'
import locale from 'iview/dist/locale/en-US';

// 引入 element
import ElementUI from 'element-ui'
import 'element-ui/lib/theme-chalk/index.css'

// 全部引入 antd
// import Antd from 'ant-design-vue';
// import 'ant-design-vue/dist/antd.css';

// 按需引入
import '@/utils/ant.js'


Vue.config.productionTip = false;

Vue.use(iView, {locale})
Vue.use(ElementUI)
// Vue.use(Antd)

new Vue({
  router, // 创建和挂载根路由实例
  store,
  render: h => h(App),
}).$mount('#app')
